import Router from '@koa/router'
import {
    deleteParkSpaceByIdController,
    getParkSpacePageController,
    postParkSpaceController,
    putParkSpaceByIdController,
    getParkSpaceOptionListController,
    deleteParkSpaceByMulIdController
} from '../controllers/parkSpace'

const parkSpaceRouter = new Router({
    prefix: '/park-space',
})

// 用户的增删改查
parkSpaceRouter.get('/', getParkSpacePageController) // 获取用户列表
parkSpaceRouter.get('/option-list', getParkSpaceOptionListController) // 获取用户列表
parkSpaceRouter.post('/', postParkSpaceController) // 添加用户
parkSpaceRouter.put('/:id', putParkSpaceByIdController) // 修改用户信息
parkSpaceRouter.delete('/mulid', deleteParkSpaceByMulIdController) // 删除用户
parkSpaceRouter.delete('/:id', deleteParkSpaceByIdController) // 删除用户

export default parkSpaceRouter
